home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
9-Digit Zip Code Directory
/
9-Digit Zip Code Directory (American Business Information) (ABIZIP-12).ISO
/
z4src.zip
/
BSDISP.C
< prev
next >
Wrap
C/C++ Source or Header
|
1993-07-15
|
3KB
|
93 lines
//----------------------------------------------------------------------------
// MODULE DESCRIPTION
//
// Module: bsdisp.c
// Title: Base library
// Notice: John M. Weeder
// Copyright (c) 1993. All rights reserved.
// This module contains proprietary information and should be
// treated as confidential.
//
//----------------------------------------------------------------------------
// MAINTENANCE HISTORY
//
// $Workfile$
// $Revision$
// $Author$
// $Date$
// $Log$
//
//----------------------------------------------------------------------------
// MODULE NARRATIVE
//
//
// This module contains .
//
// The code in this module should be written entirely in C.
// Do not use any C++ constructs.
//
// This module is portable to:
// DOS 3.X+
// MS Windows 3.X+
// OS/2 2.X+
// OS/2 2.0 PM
// SCO UNIX.
//
// The following compilers are supported:
// MSC 6.0A
// MSC/C++ 7.0
// Borland C++ 3.1 for DOS
// Borland C++ 1.0 for OS/2 2.X
// SCO UNIX cc
//
//----------------------------------------------------------------------------
#include <bs.h>
//----------------------------------------------------------------------------
// Description:
// Parameters:
// Returns: TRUE if VGA is active adaptor.
//----------------------------------------------------------------------------
BOOL FN_E DisplayIsVGA(void)
{
#if OS_DOS
USHORT usResult;
USHORT usDisplay;
_asm {
mov ax, 1A00h
int 10h
mov [usResult], ax
mov [usDisplay], bx
}
if ((usResult & 0x00FF) != 0x1A)
return FALSE;
usDisplay &= 0x00FF;
return usDisplay == 6 || usDisplay == 8;
#else
return FALSE;
#endif
}
//----------------------------------------------------------------------------
// Description: Run standard test suite
// Parameters: sTest Test to run.
// 0 Run all default tests (except).
// Returns: TRUE if successful.
//----------------------------------------------------------------------------
#if COMPILE_TEST
BOOL FN DisplayTest(SHORT sTest)
{
NOTUSED(sTest);
Output("Display IS%s VGA\n", (DisplayIsVGA() ? "": " NOT"));
return TRUE;
}
#endif
//----------------------------------------------------------------------------
//------------------------------- End of File --------------------------------
//----------------------------------------------------------------------------